<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<META http-equiv="Content-Type" content="text/html; charset=UTF-8">
<link rel="stylesheet" href="../../../style.css" type="text/css" media="screen">
<link rel="stylesheet" href="../../../print.css" type="text/css" media="print">
<meta content="ITreeDataDescriptor2,mx.controls.treeClasses.ITreeDataDescriptor2,getHierarchicalCollectionAdaptor,getNodeDepth,getParent" name="keywords">
<title>mx.controls.treeClasses.ITreeDataDescriptor2</title>
</head>
<body>
<script type="text/javascript" language="javascript" src="../../../asdoc.js"></script><script type="text/javascript" language="javascript" src="../../../cookies.js"></script><script type="text/javascript" language="javascript">
<!--
				asdocTitle = 'ITreeDataDescriptor2 - Zentrum virtUOS: virtPresenter';
				var baseRef = '../../../';
				window.onload = configPage;
			--></script>
<table style="display:none" id="titleTable" cellspacing="0" cellpadding="0" class="titleTable">
<tr>
<td align="left" class="titleTableTitle">virtPresenter AsDoc</td><td align="right" class="titleTableTopNav"><a onclick="loadClassListFrame('../../../all-classes.html')" href="../../../package-summary.html">All&nbsp;Packages</a>&nbsp;|&nbsp;<a onclick="loadClassListFrame('../../../all-classes.html')" href="../../../class-summary.html">All&nbsp;Classes</a>&nbsp;|&nbsp;<a onclick="loadClassListFrame('../../../index-list.html')" href="../../../all-index-A.html">Index</a>&nbsp;|&nbsp;<a href="../../../index.html?mx/controls/treeClasses/ITreeDataDescriptor2.html&amp;mx/controls/treeClasses/class-list.html" id="framesLink1">Frames</a><a onclick="parent.location=document.location" href="" style="display:none" id="noFramesLink1">No&nbsp;Frames</a></td><td rowspan="3" align="right" class="titleTableLogo"><img alt="Adobe Logo" title="Adobe Logo" class="logoImage" src="../../../images/logo.jpg"></td>
</tr>
<tr class="titleTableRow2">
<td align="left" id="subTitle" class="titleTableSubTitle">Interface&nbsp;ITreeDataDescriptor2</td><td align="right" id="subNav" class="titleTableSubNav"><a href="#methodSummary">Methods</a></td>
</tr>
<tr class="titleTableRow3">
<td colspan="2">&nbsp;</td>
</tr>
</table>
<script type="text/javascript" language="javascript">
<!--
if (!isEclipse() || window.name != ECLIPSE_FRAME_NAME) {titleBar_setSubTitle("Interface ITreeDataDescriptor2"); titleBar_setSubNav(false,false,false,false,false,false,true,false,false,false,false,false,false,false);}
--></script>
<div class="MainContent">
<table cellspacing="0" cellpadding="0" class="classHeaderTable">
<tr>
<td class="classHeaderTableLabel">Package</td><td><a onclick="javascript:loadClassListFrame('class-list.html')" href="package-detail.html">mx.controls.treeClasses</a></td>
</tr>
<tr>
<td class="classHeaderTableLabel">Interface</td><td class="classSignature">public interface ITreeDataDescriptor2 extends <a href="ITreeDataDescriptor.html">ITreeDataDescriptor</a></td>
</tr>
<tr>
<td class="classHeaderTableLabel">Implementors</td><td><a href="../treeClasses/DefaultDataDescriptor.html">DefaultDataDescriptor</a></td>
</tr>
</table>
<p></p>
  The ITreeDataDescriptor2 Interface defines methods for parsing and adding nodes
  to a collection of data that is displayed by a Tree control.
   <p></p>
<p>
<span class="classHeaderTableLabel">See also</span>
</p>
<div class="seeAlso">
<a href="../../collections/ICollectionView.html" target="">mx.collections.ICollectionView</a>
</div>
<br>
<hr>
</div>
<a name="methodSummary"></a>
<div class="summarySection">
<div class="summaryTableTitle">Public Methods</div>
<div class="showHideLinks">
<div class="hideInheritedMethod" id="hideInheritedMethod">
<a onclick="javascript:setInheritedVisible(false,'Method');" href="#methodSummary" class="showHideLink"><img src="../../../images/expanded.gif" class="showHideLinkImage"> Hide Inherited Public Methods</a>
</div>
<div class="showInheritedMethod" id="showInheritedMethod">
<a onclick="javascript:setInheritedVisible(true,'Method');" href="#methodSummary" class="showHideLink"><img src="../../../images/collapsed.gif" class="showHideLinkImage"> Show Inherited Public Methods</a>
</div>
</div>
<table id="summaryTableMethod" class="summaryTable " cellpadding="3" cellspacing="0">
<tr>
<th>&nbsp;</th><th colspan="2">Method</th><th class="summaryTableOwnerCol">Defined&nbsp;by</th>
</tr>
<tr class="hideInheritedMethod">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol"><img class="inheritedSummaryImage" title="Inherited" alt="Inherited" src="../../../images/inheritedSummary.gif"></td><td class="summaryTableSignatureCol">
<div class="summarySignature">
<a class="signatureLink" href="ITreeDataDescriptor.html#addChildAt()">addChildAt</a>(parent:Object, newChild:Object, index:int, model:Object = null):Boolean</div>
<div class="summaryTableDescription">
      Adds a child node to a node at the specified index.</div>
</td><td class="summaryTableOwnerCol"><a href="ITreeDataDescriptor.html">ITreeDataDescriptor</a></td>
</tr>
<tr class="hideInheritedMethod">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol"><img class="inheritedSummaryImage" title="Inherited" alt="Inherited" src="../../../images/inheritedSummary.gif"></td><td class="summaryTableSignatureCol">
<div class="summarySignature">
<a class="signatureLink" href="ITreeDataDescriptor.html#getChildren()">getChildren</a>(node:Object, model:Object = null):<a href="../../collections/ICollectionView.html">ICollectionView</a>
</div>
<div class="summaryTableDescription">
      Provides access to a node's children, returning a collection
      view of children if they exist.</div>
</td><td class="summaryTableOwnerCol"><a href="ITreeDataDescriptor.html">ITreeDataDescriptor</a></td>
</tr>
<tr class="hideInheritedMethod">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol"><img class="inheritedSummaryImage" title="Inherited" alt="Inherited" src="../../../images/inheritedSummary.gif"></td><td class="summaryTableSignatureCol">
<div class="summarySignature">
<a class="signatureLink" href="ITreeDataDescriptor.html#getData()">getData</a>(node:Object, model:Object = null):Object</div>
<div class="summaryTableDescription">
      Gets the data from a node.</div>
</td><td class="summaryTableOwnerCol"><a href="ITreeDataDescriptor.html">ITreeDataDescriptor</a></td>
</tr>
<tr class="">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol">&nbsp;</td><td class="summaryTableSignatureCol">
<div class="summarySignature">
<a class="signatureLink" href="#getHierarchicalCollectionAdaptor()">getHierarchicalCollectionAdaptor</a>(hierarchicalData:<a href="../../collections/ICollectionView.html">ICollectionView</a>, uidFunction:Function, openItems:Object, model:Object = null):<a href="../../collections/ICollectionView.html">ICollectionView</a>
</div>
<div class="summaryTableDescription">
      Returns an ICollectionView instance that makes the hierarchical data appear
      as if it was a linear ICollectionView instance.</div>
</td><td class="summaryTableOwnerCol">ITreeDataDescriptor2</td>
</tr>
<tr class="">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol">&nbsp;</td><td class="summaryTableSignatureCol">
<div class="summarySignature">
<a class="signatureLink" href="#getNodeDepth()">getNodeDepth</a>(node:Object, iterator:<a href="../../collections/IViewCursor.html">IViewCursor</a>, model:Object = null):int</div>
<div class="summaryTableDescription">
      Returns the depth of the node, meaning the number of ancestors it has.</div>
</td><td class="summaryTableOwnerCol">ITreeDataDescriptor2</td>
</tr>
<tr class="">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol">&nbsp;</td><td class="summaryTableSignatureCol">
<div class="summarySignature">
<a class="signatureLink" href="#getParent()">getParent</a>(node:Object, collection:<a href="../../collections/ICollectionView.html">ICollectionView</a>, model:Object = null):Object</div>
<div class="summaryTableDescription">
      Returns the parent of the node
      The parent of a top-level node is <code>null</code>.</div>
</td><td class="summaryTableOwnerCol">ITreeDataDescriptor2</td>
</tr>
<tr class="hideInheritedMethod">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol"><img class="inheritedSummaryImage" title="Inherited" alt="Inherited" src="../../../images/inheritedSummary.gif"></td><td class="summaryTableSignatureCol">
<div class="summarySignature">
<a class="signatureLink" href="ITreeDataDescriptor.html#hasChildren()">hasChildren</a>(node:Object, model:Object = null):Boolean</div>
<div class="summaryTableDescription">
      Tests for the existence of children in a non-terminating node.</div>
</td><td class="summaryTableOwnerCol"><a href="ITreeDataDescriptor.html">ITreeDataDescriptor</a></td>
</tr>
<tr class="hideInheritedMethod">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol"><img class="inheritedSummaryImage" title="Inherited" alt="Inherited" src="../../../images/inheritedSummary.gif"></td><td class="summaryTableSignatureCol">
<div class="summarySignature">
<a class="signatureLink" href="ITreeDataDescriptor.html#isBranch()">isBranch</a>(node:Object, model:Object = null):Boolean</div>
<div class="summaryTableDescription">
      Tests a node for termination.</div>
</td><td class="summaryTableOwnerCol"><a href="ITreeDataDescriptor.html">ITreeDataDescriptor</a></td>
</tr>
<tr class="hideInheritedMethod">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol"><img class="inheritedSummaryImage" title="Inherited" alt="Inherited" src="../../../images/inheritedSummary.gif"></td><td class="summaryTableSignatureCol">
<div class="summarySignature">
<a class="signatureLink" href="ITreeDataDescriptor.html#removeChildAt()">removeChildAt</a>(parent:Object, child:Object, index:int, model:Object = null):Boolean</div>
<div class="summaryTableDescription">
      Removes a child node to a node at the specified index.</div>
</td><td class="summaryTableOwnerCol"><a href="ITreeDataDescriptor.html">ITreeDataDescriptor</a></td>
</tr>
</table>
</div>
<script type="text/javascript" language="javascript">
<!--
showHideInherited();
--></script>
<div class="MainContent">
<a name="methodDetail"></a>
<div class="detailSectionHeader">Method detail</div>
<a name="getHierarchicalCollectionAdaptor()"></a>
<table cellspacing="0" cellpadding="0" class="detailHeader">
<tr>
<td class="detailHeaderName">getHierarchicalCollectionAdaptor</td><td class="detailHeaderParens">()</td><td class="detailHeaderType">method</td>
</tr>
</table>
<div class="detailBody">
<code>public function getHierarchicalCollectionAdaptor(hierarchicalData:<a href="../../collections/ICollectionView.html">ICollectionView</a>, uidFunction:Function, openItems:Object, model:Object = null):<a href="../../collections/ICollectionView.html">ICollectionView</a></code><p>
      Returns an ICollectionView instance that makes the hierarchical data appear
      as if it was a linear ICollectionView instance.
           </p><span class="label">Parameters</span>
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="20px"></td><td><code><span class="label">hierarchicalData</span>:<a href="../../collections/ICollectionView.html">ICollectionView</a></code> &mdash; The hierarchical data.
           </td>
</tr>
<tr>
<td class="paramSpacer">&nbsp;</td>
</tr>
<tr>
<td width="20px"></td><td><code><span class="label">uidFunction</span>:Function</code> &mdash; A function that takes an Object and returns the UID, as a String. 
      This parameter is usually the <code>Tree.itemToUID()</code> method.
           </td>
</tr>
<tr>
<td class="paramSpacer">&nbsp;</td>
</tr>
<tr>
<td width="20px"></td><td><code><span class="label">openItems</span>:Object</code> &mdash; The items that have been opened or set opened.
           </td>
</tr>
<tr>
<td class="paramSpacer">&nbsp;</td>
</tr>
<tr>
<td width="20px"></td><td><code><span class="label">model</span>:Object</code> (default = <code>null</code>)<code></code> &mdash; The collection to which this node belongs.
     
      </td>
</tr>
</table>
<p></p>
<span class="label">Returns</span>
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="20"></td><td><code><a href="../../collections/ICollectionView.html">ICollectionView</a></code> &mdash; 
                        An ICollectionView instance.
           
                        
                     </td>
</tr>
</table>
<p>
<span class="label">See also</span>
</p>
<div class="seeAlso">
<a href="../../controls/Tree.html" target="">mx.controls.Tree</a>
</div>
</div>
<a name="getNodeDepth()"></a>
<table cellspacing="0" cellpadding="0" class="detailHeader">
<tr>
<td class="detailHeaderName">getNodeDepth</td><td class="detailHeaderParens">()</td><td class="detailHeaderType">method</td><td class="detailHeaderRule">&nbsp;</td>
</tr>
</table>
<div class="detailBody">
<code>public function getNodeDepth(node:Object, iterator:<a href="../../collections/IViewCursor.html">IViewCursor</a>, model:Object = null):int</code><p>
      Returns the depth of the node, meaning the number of ancestors it has.
           </p><span class="label">Parameters</span>
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="20px"></td><td><code><span class="label">node</span>:Object</code> &mdash; The Object that defines the node.
     
      </td>
</tr>
<tr>
<td class="paramSpacer">&nbsp;</td>
</tr>
<tr>
<td width="20px"></td><td><code><span class="label">iterator</span>:<a href="../../collections/IViewCursor.html">IViewCursor</a></code> &mdash; An IViewCursor instance that could be used to do the calculation.
           </td>
</tr>
<tr>
<td class="paramSpacer">&nbsp;</td>
</tr>
<tr>
<td width="20px"></td><td><code><span class="label">model</span>:Object</code> (default = <code>null</code>)<code></code> &mdash; The collection to which this node belongs.
      
      </td>
</tr>
</table>
<p></p>
<span class="label">Returns</span>
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="20"></td><td><code>int</code> &mdash; The depth of the node, where 0 corresponds to the top level, 
      and -1 if the depth cannot be calculated.
     </td>
</tr>
</table>
</div>
<a name="getParent()"></a>
<table cellspacing="0" cellpadding="0" class="detailHeader">
<tr>
<td class="detailHeaderName">getParent</td><td class="detailHeaderParens">()</td><td class="detailHeaderType">method</td><td class="detailHeaderRule">&nbsp;</td>
</tr>
</table>
<div class="detailBody">
<code>public function getParent(node:Object, collection:<a href="../../collections/ICollectionView.html">ICollectionView</a>, model:Object = null):Object</code><p>
      Returns the parent of the node
      The parent of a top-level node is <code>null</code>.
           </p><span class="label">Parameters</span>
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="20px"></td><td><code><span class="label">node</span>:Object</code> &mdash; The Object that defines the node.
           </td>
</tr>
<tr>
<td class="paramSpacer">&nbsp;</td>
</tr>
<tr>
<td width="20px"></td><td><code><span class="label">collection</span>:<a href="../../collections/ICollectionView.html">ICollectionView</a></code> &mdash; An ICollectionView instance that could be used to do the calculation.
           </td>
</tr>
<tr>
<td class="paramSpacer">&nbsp;</td>
</tr>
<tr>
<td width="20px"></td><td><code><span class="label">model</span>:Object</code> (default = <code>null</code>)<code></code> &mdash; The collection to which this node belongs.
     
      </td>
</tr>
</table>
<p></p>
<span class="label">Returns</span>
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="20"></td><td><code>Object</code> &mdash; The parent node containing the node as child, 
      <code>null</code> for a top-level node,  
      and <code>undefined</code> if the parent cannot be determined.
     </td>
</tr>
</table>
</div>
<br>
<br>
<hr>
<br>
<p></p>
<center class="copyright"> 
</center>
</div>
</body>
</html>
<!-- -->
